The present invention is directed to the art of digital image processing and, more particularly, to a method and apparatus for overriding segmentation classification information generated during single channel segmentation of a multi-channel color image. The present invention is especially well suited for addressing the white/black detection failure modes prevalent in single channel segmentation schemes by selectively re-classifying appropriate pixels as an xe2x80x9cotherxe2x80x9d class and will be described with particular reference thereto. However, it is to be understood that the present invention has broader application and can be used to compensate for a wide range of segmentation failure modes and can be used with a wide variety of digital images and other digital information or data.
Segmentation is an important area of electronic image processing, particularly color image processing. In systems that use image segmentation information such as page description language (PDL) or other document description type systems, a plurality of predefined classes detected in compound documents are used for image storage, processing, rendering, and for other functions. The set of predefined classes includes text, halftone, contone, line art, picture, and many more. It is important, therefore, for the segmentation scheme used in classifying the color image to be able to correctly recognize and accurately identify pixels belonging to the set of classification groups supported by the PDL. That is, it is important for the segmentation technique to be matched to the document description system so that each pixel is classified as one of a plurality of predetermined recognized classification groups.
Sometimes, one or more pixels in a color image cannot be classified as belonging to one of the plurality of predetermined classification groups with a reasonable certainty. In that case, some prior art segmentation schemes label the indeterminate pixel as belonging to an xe2x80x9cotherxe2x80x9d class. As an example, if a segmentation scheme can classify color image pixels as belonging to either a text or contone group only, and then halftone pixels are encountered in the digital color image, the segmentation processing would be unable to label the halftone pixels as either text or contone with a reasonable degree of certainty. One solution is to incorrectly label the halftone pixels as being either a text or contone type class even though the halftone pixel belongs to neither. Another solution is to merely label the halftone pixel as belonging to an xe2x80x9cotherxe2x80x9d class whereupon similar pixels of indeterminate class must be further processed or handled in some unique manner. The use of the xe2x80x9cotherxe2x80x9d class in color image segmentation schemes for identifying portions of an image having indeterminate classification characteristics has proven to be effective.
In more complicated segmentation schemes 10, such as the one shown at FIG. 1, each color space of a color input image 12 is processed by a separate independent full scale single channel segmentation processing unit that operates on each pixel of the multi-channel color input image simultaneously. In the example shown in FIG. 1, each pixel in the red color space R is processed by a first segmentation processing unit 14. Similarly, each pixel in the green and blue color spaces G, B is processed by an independent segmentation processing unit 16, 18, respectively. Each of the segmentation processing units generates a pixel classification output signal for use by a discriminator circuit 20 to appropriately label the processed pixel as belonging to one of a plurality of predetermined segmentation classes. In the segmentation scheme 10 shown in the figure, each segmentation processing unit operates simultaneously and in parallel to process individual pixels of the color input image 12 one at a time until each of the pixels are provided with an appropriate segmentation class tag for use downstream in the PDL.
Although the segmentation scheme 10 shown in FIG. 1 is fairly robust, it is quite complicated and somewhat costly to implement. Accordingly, a technique known as xe2x80x9csingle channel segmentationxe2x80x9d for classifying pixels of color input images has been developed. FIG. 2 shows an example of a prior art single channel color image segmentation circuit 22. As illustrated there, only a single segmentation processing unit 24 is used to generate pixel classification signals for use by the discriminator circuit 26 to generate the appropriate pixel class tags. Typically, a single channel for input into the segmentation processing unit 24 is created from the multiple color channels, e.g. R, G, B of the color input image 28 using a technique known as projection. In projection, an inner product is determined between the multi-channel input video and a single predetermined direction. As an example, if the input video is an RGB image, the video value of each pixel can be represented by Vin=[RinGinBin]xe2x80x2. A single channel for segmentation of the video, SV, can be determined from SV=Wxe2x80x2*Vin where W is a weighting vector: W=[W1W2W3]xe2x80x2. In order to ensure that the output is limited to 8 bits, the weighing vector is typically normalized by xcexa3iwi=1.
One of the problems associated with single channel detection schemes is that occasionally very important information is lost during the conversion from three to one channel. As noted above, however, it is costly to include all three channels in performing segmentation. Accordingly, the single channel segmentation scheme shown in FIG. 2 is often employed where cost is a concern and where segmentation accuracy is not a major concern.
Typical prior art single channel segmentation schemes are prone to several failure modes including classifying certain bright colors (e.g. yellow) as the class xe2x80x9cwhitexe2x80x9d and certain dark colors (e.g. purple) as the class xe2x80x9cblackxe2x80x9d. White and black detection are the predominant failure modes. Typically, white is used as background in color images. Black is used as a key identifier in text recognition and to make decisions in certain compression schemes. In image processing, the white/color background class is very important. The black/white background class is used often to separate various regions within the color input image, for compression algorithms where background information (white/black class) is heavily compressed to separate windows within the color input image wherein the various windows are stored and/or processed independently or separately downstream and the like. White/black detection is therefore critical because failure to accurately identify background pixels in the color input image adversely affects image processing downstream.
With reference now to FIGS. 3a and 3b, one particularly acute failure mode of the single channel segmentation processing scheme will be described. As noted above, in single channel segmentation, a single channel projection vector is formed by generating a weighted vector of the three color channels into a single predetermined normalized output vector. When the plurality of color channels from the color input image are projected onto a single vector for processing, much of the color information may be lost from one or more of the color channels resulting in a single vector which essentially xe2x80x9clooksxe2x80x9d white to the segmentation processing unit 24. Essentially, color information critical to proper segmentation may be lost during the pre-segmentation processing. When this happens, a pixel is labeled as belonging to a xe2x80x9cwhitexe2x80x9d or xe2x80x9cbackgroundxe2x80x9d class in error. Accordingly, there is a need for overriding a white classification when color content information is obliterated in the pre-segmentation processing.
Another failure mode of the single channel segmentation scheme affects white and black detection as well. With reference to FIG. 3a, a color input image 30 includes a continuous color region 32 having a first color area 34 separated from a second color area 36 by a yellow line or bar 38. When the plurality of color channel vectors of the yellow halftone line portion 38 of the continuous halftone region 32 is projected onto a single vector, a white projection vector typically results. Thus, the yellow halftone area is inappropriately declared to be white. Green halftones can also have a large white component as well. In that case, a green halftone area in the continuous halftone region 34 would similarly likely be classified as background or white. Generally, colors within the green through yellow range project to a white or background composite vector.
In another example, shown in FIG. 3b, a halftone color sweep region 40 includes a yellow halftone sweep portion 42 and a green halftone sweep portion 44. During typical projection conversion of the plurality color channels to a single channel prior to segmentation, both the yellow halftone sweep portion 42 and the green halftone sweep portion 44 of the halftone color sweep region 40 would typically be interpreted as being background or white portions of the color input image because the projection of the orthogonal vectors onto a single projection vector masks much of the usable color information.
Accordingly, there is a need in single channel segmentation of color images for a method and apparatus for reclassifying pixels which were inappropriately classified as belonging to the xe2x80x9cblackxe2x80x9d or xe2x80x9cwhite/backgroundxe2x80x9d class. It would be advantageous to provide a method and apparatus that is relatively inexpensive and simple to implement which could selectively operate on the color input image pixels whenever the single channel segmentation scheme is likely to be operating in one of a plurality of known failure modes such as, for example, black/white detection.
It would be advantageous to provide an inexpensive secondary classification circuit which could perform very simple operations on the color input image pixel to override the primary segmentation circuit, if necessary, when the primary segmentation circuit is likely to be in one a set of known failure modes.
It would further be desirable to provide a method and apparatus to re-classify pixels that were previously inappropriately classified as background and/or white/black by a primary segmentation circuit.
In accordance with one aspect of the present invention, an inexpensive secondary classifier circuit is provide for generating xe2x80x9cotherxe2x80x9d pixel class tags for use during single channel segmentation of color images.
In accordance with a more limited aspect of the present invention, the inexpensive secondary classifier circuit is responsive to a predetermined set of signals generated by the single channel segmentation circuit, preferably signals indicative of the segmentation circuit being in one of a plurality of known failure modes, such as white/black detection.
In accordance with a still further aspect of the invention, the secondary classifier circuit includes simple arithmetic and logic means for calculating information content of each color channel in the input image pixels and generating a classification override signal when the single channel segmentation circuit, misclassifies a pixel as being background and/or white/black.
A primary advantage of the invention is an accurate and efficient segmentation of input image pixels into classes.
It is another advantage of the invention is that performance results similar to multi-channel segmentation schemes are achieved with a substantially reduced hardware and software investment.
These and other advantages and benefits of the present invention will become apparent to those of ordinary skill in the art upon reading and understanding the following detailed description of the preferred embodiments.